package com.itheima.mapper;


import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.itheima.pojo.StaffMessage;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.ResultMap;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;

import java.util.List;
import java.util.Map;

@Mapper
public interface StaffMessageMapper {
//H04-新增员工

    @ResultMap("StaffMessageMapper")
    Integer add(StaffMessage staffMessage);
//判断是否重复

    @ResultMap("StaffMessageMapper")
    Integer judge(String idNumber);
//H05-启用/禁用/修改

    @ResultMap("StaffMessageMapper")
    Integer update(StaffMessage staffMessage);


    @Select("select * from staffmessage where username = #{username} and password=#{password} ")
    List<StaffMessage> longin(StaffMessage a) ;

    @ResultMap("StaffMessageMapper")
    List<StaffMessage> select(String name);

    @ResultMap("StaffMessageMapper")
    StaffMessage findById(Integer id);













}
